// entries:返回数组的可迭代对象。
let fruits = ["Banana", "Orange", "Apple", "Mango"];
let res = fruits.entries();
for (let i = 0; i < fruits.length; i++) {
  // if(res.next().done) return
  console.log(res.next());
  /*
    { value: [ 0, 'Banana' ], done: false }
    { value: [ 1, 'Orange' ], done: false }
    { value: [ 2, 'Apple' ], done: false }
    { value: [ 3, 'Mango' ], done: false }
  */
}

console.log(res.next(), fruits);
